<% modelname = Teacher.human_name %>
<% form_for(@teacher, :html => { :multipart => true }) do |f| %>
  <%= f.error_messages %>

  <table class="form_table" cellpadding="0" cellspacing="0" style="border-top: 0px;">

    <caption style="border-bottom: 0px;">
      <%= "#{controller.action_name == 'edit' ? t(:update_x, :x => modelname) : t(:create_x, :x => modelname)}" %>
    </caption>

    <tr>
      <td class="label"><%= f.label AcademicDegree.human_name %></td>
      <td>
          <%=f.select(:academic_degree_id , AcademicDegree.all.collect {|p| [ p.name, p.id ] }, { :include_blank => false }) %>
      </td>

      <td class="label"><%= f.label Teacher.human_attribute_name(:is_active) %></td>
      <td><%= f.check_box :is_active %></td>
    </tr>
    
   <%= render :partial => 'people/form_fields_for', :locals => {:person => @teacher.person} %>

    <tr>
      <td class="submit" colspan="4">
        <%= f.submit controller.action_name == 'edit' ? t(:update) : t(:create) %>
      </td>
    </tr>
  </table>

<% end %>

